package io.choerodon.manager.api.controller.v1

import io.choerodon.manager.IntegrationTestConfiguration
import io.choerodon.manager.app.service.ApiService
import io.choerodon.manager.app.service.SwaggerService
import io.choerodon.manager.app.service.impl.ApiServiceImpl
import io.choerodon.manager.app.service.DocumentService
import io.choerodon.manager.infra.dto.RouteDTO
import io.choerodon.manager.infra.feign.IamClient
import io.choerodon.manager.infra.mapper.RouteMapper
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.boot.test.context.SpringBootTest
import org.springframework.boot.test.web.client.TestRestTemplate
import org.springframework.context.annotation.Import
import org.springframework.data.redis.core.StringRedisTemplate
import org.springframework.data.redis.core.ZSetOperations
import spock.lang.Specification
import springfox.documentation.swagger.web.SwaggerResource

import static org.springframework.boot.test.context.SpringBootTest.WebEnvironment.RANDOM_PORT

/**
 * @author superlee
 */
@SpringBootTest(webEnvironment = RANDOM_PORT)
@Import(IntegrationTestConfiguration)
class ApiControllerSpec extends Specification {
    @Autowired
    private TestRestTemplate restTemplate

    @Autowired
    private ApiController apiController

    private SwaggerService mockSwaggerService = Mock(SwaggerService)

    private ApiService mockApiService = Mock(ApiService)

    def setup() {
        apiController.setSwaggerService(mockSwaggerService)
        apiController.setApiService(mockApiService)
    }

    def "Resources"() {
        when: "调用查询不包含跳过的服务的路由列表接口"
        def entity = restTemplate.getForEntity("/v1/swaggers/resources", String)

        then: "校验状态码和调用次数"
        entity.statusCode.is2xxSuccessful()
        1 * mockSwaggerService.getSwaggerResource()
        0 * _
    }

    def "QueryByNameAndVersion"() {
        given: "构造请求参数"
        def serviceName = "manager"
        def version = "0.10.0"
        def map = ["service_prefix": serviceName, "version": version, "params": "params", "name": "name", "description": "description"]

        when: "调用查询服务接口"
        def entity = restTemplate.getForEntity("/v1/swaggers/{service_prefix}/controllers" +
                "?service_prefix={service_prefix}&version={version}&params={params}&name={name}&description={description}", String, map)

        then: "校验状态码和调用次数"
        entity.statusCode.is2xxSuccessful()
//        1 * mockApiService.getControllers(serviceName, version, _, _, _ as HashMap)
//        0 * _
    }

    def "QueryPathDetail"() {
        given: '构造请求参数'
        def serviceName = "manager"
        def version = 'test_version'
        def operationId = '1'
        def name = "api"
        def map = ["service_prefix": serviceName, "version": version, "operation_id": operationId, "name": name]

        when: "调用根据path的url和method查询单个path接口"
        def entity = restTemplate.getForEntity("/v1/swaggers/{service_prefix}/controllers/{name}/paths" +
                "?version={version}&operation_id={operation_id}", String, map)

        then: "校验状态码和调用次数"
        entity.statusCode.is2xxSuccessful()
        1 * mockApiService.queryPathDetail(serviceName, version, name, operationId)
        0 * _
    }

    def "QueryInstancesAndApiCount"() {
        given:
        DocumentService iDocumentService = Mock(DocumentService)
        SwaggerService swaggerService = Mock(SwaggerService)
        RouteMapper routeMapper = Mock(RouteMapper)
        ApiServiceImpl impl = new ApiServiceImpl(iDocumentService, routeMapper, Mock(StringRedisTemplate), Mock(IamClient), swaggerService)
        ApiController controller = new ApiController(null, impl)

        SwaggerResource swaggerResource = new SwaggerResource()
        swaggerResource.setName("manager:manager-service")
        swaggerResource.setLocation("/docs/manager?version=null_version")
        swaggerResource.setSwaggerVersion("2.0")
        List<SwaggerResource> resources = new ArrayList<>()
        resources << swaggerResource
        swaggerService.getSwaggerResource() >> resources
        def file = new File(this.class.getResource('/swagger.json').toURI())
        iDocumentService.fetchSwaggerJsonByService(_, _) >> { file.getText('UTF-8') }
        iDocumentService.expandSwaggerJson(_, _, _) >> { file.getText('UTF-8') }
        RouteDTO routeDO = new RouteDTO()
        routeDO.setName("mamager")
        routeDO.setServiceId("manager-service")
        routeMapper.selectOne(_) >> routeDO

        when:
        def entity = controller.queryInstancesAndApiCount()
        then:
        Integer.valueOf(entity.getBody().get("apiCounts").getAt(0)) == 25
    }

    def "QueryServiceInvoke"() {
        given:
        StringRedisTemplate redisTemplate = Mock(StringRedisTemplate)
        SwaggerService swaggerService = Mock(SwaggerService)
        ApiServiceImpl apiService = new ApiServiceImpl(null, null, redisTemplate, Mock(IamClient), swaggerService)
        ApiController controller = new ApiController(null, apiService)
        List swaggerList = new ArrayList()
        SwaggerResource swaggerResource = Mock(SwaggerResource)
        swaggerList << swaggerResource
        swaggerService.getSwaggerResource() >> swaggerList
        swaggerResource.getName() >> "manager:manager-service"
        swaggerResource.getLocation() >> "/docs/manager?version=null_version"
        ZSetOperations zSetOperations = Mock(ZSetOperations)
        redisTemplate.opsForZSet() >> zSetOperations
        Set<ZSetOperations.TypedTuple<String>> tuples = new LinkedHashSet<>()
        ZSetOperations.TypedTuple<String> tuple = Mock(ZSetOperations.TypedTuple)
        zSetOperations.rangeWithScores(_, _, _) >> tuples
        tuples << tuple
        tuple.getValue() >> "manager-service"
        tuple.getScore() >> 1

        when:
        def result = controller.queryServiceInvoke("2018-11-02", "2018-11-05")
        def list = (Set) result.getBody().get("date")
        then:
        list.contains("2018-11-02") && list.contains("2018-11-05")
    }

    def "QueryApiInvoke"() {
        given:
        StringRedisTemplate redisTemplate = Mock(StringRedisTemplate)
        SwaggerService swaggerService = Mock(SwaggerService)
        ApiServiceImpl apiService = new ApiServiceImpl(null, null, redisTemplate, Mock(IamClient), swaggerService)
        ApiController controller = new ApiController(null, apiService)
        ZSetOperations zSetOperations = Mock(ZSetOperations)
        redisTemplate.opsForZSet() >> zSetOperations
        Set<ZSetOperations.TypedTuple<String>> tuples = new LinkedHashSet<>()
        ZSetOperations.TypedTuple<String> tuple = Mock(ZSetOperations.TypedTuple)
        zSetOperations.rangeWithScores(_, _, _) >> tuples
        tuples << tuple
        tuple.getValue() >> "manager-service"
        tuple.getScore() >> 1

        when:
        def result = controller.queryApiInvoke("2018-11-02", "2018-11-05", "manager-service")
        def list = (Set) result.getBody().get("date")
        then:
        list.contains("2018-11-02") && list.contains("2018-11-05")
    }

    def "QueryTreeMenu"() {
        given:
        SwaggerService swaggerService = Mock(SwaggerService)
        DocumentService iDocumentService = Mock(DocumentService)
        StringRedisTemplate stringRedisTemplate = Mock(StringRedisTemplate)
        ApiServiceImpl apiService = new ApiServiceImpl(iDocumentService, null, stringRedisTemplate, Mock(IamClient), swaggerService)
        ApiController controller = new ApiController(null, apiService)
        List<SwaggerResource> resources = new ArrayList<>()
        SwaggerResource resource = new SwaggerResource()
        resource.setName("manager:manager-service")
        resource.setLocation("/docs/manager?version=null_version")
        resources << resource
        swaggerService.getSwaggerResource() >> resources
        def file = new File(this.class.getResource('/swagger.json').toURI())
        iDocumentService.fetchSwaggerJsonByService(_, _) >> { file.getText('UTF-8') }

        when:
        controller.queryTreeMenu()
        then:
        true
    }

    def "QueryTreeMenu(from cache)"() {
        given:
        SwaggerService swaggerService = Mock(SwaggerService)
        DocumentService iDocumentService = Mock(DocumentService)
        StringRedisTemplate stringRedisTemplate = Mock(StringRedisTemplate)
        ApiServiceImpl apiService = new ApiServiceImpl(iDocumentService, null, stringRedisTemplate, Mock(IamClient), swaggerService)
        ApiController controller = new ApiController(null, apiService)
        List<SwaggerResource> resources = new ArrayList<>()
        SwaggerResource resource = new SwaggerResource()
        resource.setName("manager:manager-service")
        resource.setLocation("/docs/manager?version=null_version")
        resources << resource
        swaggerService.getSwaggerResource() >> resources
        def file = new File(this.class.getResource('/swagger.json').toURI())
        iDocumentService.fetchSwaggerJsonByService(_, _) >> { file.getText('UTF-8') }
//        ValueOperations valueOperations = Mock(ValueOperations)

        when:
        controller.queryTreeMenu()
        then:
        true
//        1 * stringRedisTemplate.hasKey(_) >> true
//        1 * stringRedisTemplate.opsForValue() >> valueOperations
//        1 * valueOperations.get(_) >> "[{\"children\":[{\"refController\":\"ldap-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByOrgIdUsingGET\",\"title\":\"/v1/organizations/{organization_id}/ldaps\",\"version\":\"v1\",\"key\":\"0-0-0-0\"},{\"refController\":\"ldap-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_2\",\"title\":\"/v1/organizations/{organization_id}/ldaps\",\"version\":\"v1\",\"key\":\"0-0-0-1\"},{\"refController\":\"ldap-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPOST_2\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}\",\"version\":\"v1\",\"key\":\"0-0-0-2\"},{\"refController\":\"ldap-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteUsingDELETE_3\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}\",\"version\":\"v1\",\"key\":\"0-0-0-3\"},{\"refController\":\"ldap-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"disableLdapUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}/disable\",\"version\":\"v1\",\"key\":\"0-0-0-4\"},{\"refController\":\"ldap-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"enableLdapUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}/enable\",\"version\":\"v1\",\"key\":\"0-0-0-5\"},{\"refController\":\"ldap-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"latestHistoryUsingGET\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}/latest_history\",\"version\":\"v1\",\"key\":\"0-0-0-6\"},{\"refController\":\"ldap-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"stopUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}/stop\",\"version\":\"v1\",\"key\":\"0-0-0-7\"},{\"refController\":\"ldap-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"syncUsersUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}/sync_users\",\"version\":\"v1\",\"key\":\"0-0-0-8\"},{\"refController\":\"ldap-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"testConnectUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/ldaps/{id}/test_connect\",\"version\":\"v1\",\"key\":\"0-0-0-9\"}],\"title\":\"ldap-controller\",\"key\":\"0-0-0\"},{\"children\":[{\"refController\":\"book-mark-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_1\",\"title\":\"/v1/bookmarks\",\"version\":\"v1\",\"key\":\"0-0-1-0\"},{\"refController\":\"book-mark-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST\",\"title\":\"/v1/bookmarks\",\"version\":\"v1\",\"key\":\"0-0-1-1\"},{\"refController\":\"book-mark-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT\",\"title\":\"/v1/bookmarks\",\"version\":\"v1\",\"key\":\"0-0-1-2\"},{\"refController\":\"book-mark-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteUsingDELETE_1\",\"title\":\"/v1/bookmarks/{id}\",\"version\":\"v1\",\"key\":\"0-0-1-3\"}],\"title\":\"book-mark-controller\",\"key\":\"0-0-1\"},{\"children\":[{\"refController\":\"access-token-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET\",\"title\":\"/v1/token\",\"version\":\"v1\",\"key\":\"0-0-2-0\"},{\"refController\":\"access-token-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteUsingDELETE\",\"title\":\"/v1/token\",\"version\":\"v1\",\"key\":\"0-0-2-1\"}],\"title\":\"access-token-controller\",\"key\":\"0-0-2\"},{\"children\":[{\"refController\":\"lookup-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_5\",\"title\":\"/v1/lookups\",\"version\":\"v1\",\"key\":\"0-0-3-0\"},{\"refController\":\"lookup-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_3\",\"title\":\"/v1/lookups\",\"version\":\"v1\",\"key\":\"0-0-3-1\"},{\"refController\":\"lookup-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listByCodeUsingGET\",\"title\":\"/v1/lookups/code\",\"version\":\"v1\",\"key\":\"0-0-3-2\"},{\"refController\":\"lookup-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByIdUsingGET\",\"title\":\"/v1/lookups/{id}\",\"version\":\"v1\",\"key\":\"0-0-3-3\"},{\"refController\":\"lookup-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_2\",\"title\":\"/v1/lookups/{id}\",\"version\":\"v1\",\"key\":\"0-0-3-4\"},{\"refController\":\"lookup-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteUsingDELETE_4\",\"title\":\"/v1/lookups/{id}\",\"version\":\"v1\",\"key\":\"0-0-3-5\"}],\"title\":\"lookup-controller\",\"key\":\"0-0-3\"},{\"children\":[{\"refController\":\"client-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_2\",\"title\":\"/v1/organizations/{organization_id}/clients\",\"version\":\"v1\",\"key\":\"0-0-4-0\"},{\"refController\":\"client-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_1\",\"title\":\"/v1/organizations/{organization_id}/clients\",\"version\":\"v1\",\"key\":\"0-0-4-1\"},{\"refController\":\"client-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/clients/check\",\"version\":\"v1\",\"key\":\"0-0-4-2\"},{\"refController\":\"client-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"createInfoUsingGET\",\"title\":\"/v1/organizations/{organization_id}/clients/createInfo\",\"version\":\"v1\",\"key\":\"0-0-4-3\"},{\"refController\":\"client-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByNameUsingGET\",\"title\":\"/v1/organizations/{organization_id}/clients/query_by_name\",\"version\":\"v1\",\"key\":\"0-0-4-4\"},{\"refController\":\"client-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET\",\"title\":\"/v1/organizations/{organization_id}/clients/{client_id}\",\"version\":\"v1\",\"key\":\"0-0-4-5\"},{\"refController\":\"client-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/clients/{client_id}\",\"version\":\"v1\",\"key\":\"0-0-4-6\"},{\"refController\":\"client-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteUsingDELETE_2\",\"title\":\"/v1/organizations/{organization_id}/clients/{client_id}\",\"version\":\"v1\",\"key\":\"0-0-4-7\"}],\"title\":\"client-controller\",\"key\":\"0-0-4\"},{\"children\":[{\"refController\":\"permission-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsingGET_2\",\"title\":\"/v1/permissions\",\"version\":\"v1\",\"key\":\"0-0-5-0\"},{\"refController\":\"permission-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"queryByRoleIdsUsingPOST\",\"title\":\"/v1/permissions\",\"version\":\"v1\",\"key\":\"0-0-5-1\"},{\"refController\":\"permission-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteByCodeUsingDELETE\",\"title\":\"/v1/permissions\",\"version\":\"v1\",\"key\":\"0-0-5-2\"},{\"refController\":\"permission-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkPermissionUsingPOST\",\"title\":\"/v1/permissions/checkPermission\",\"version\":\"v1\",\"key\":\"0-0-5-3\"},{\"refController\":\"permission-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_5\",\"title\":\"/v1/permissions/permissionList\",\"version\":\"v1\",\"key\":\"0-0-5-4\"}],\"title\":\"permission-controller\",\"key\":\"0-0-5\"},{\"children\":[{\"refController\":\"organization-user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_6\",\"title\":\"/v1/organizations/{organization_id}/users\",\"version\":\"v1\",\"key\":\"0-0-6-0\"},{\"refController\":\"organization-user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"importUsersFromExcelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/users/batch_import\",\"version\":\"v1\",\"key\":\"0-0-6-1\"},{\"refController\":\"organization-user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST_4\",\"title\":\"/v1/organizations/{organization_id}/users/check\",\"version\":\"v1\",\"key\":\"0-0-6-2\"},{\"refController\":\"organization-user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"downloadTemplatesUsingGET\",\"title\":\"/v1/organizations/{organization_id}/users/download_templates\",\"version\":\"v1\",\"key\":\"0-0-6-3\"},{\"refController\":\"organization-user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/users/search\",\"version\":\"v1\",\"key\":\"0-0-6-4\"},{\"refController\":\"organization-user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_4\",\"title\":\"/v1/organizations/{organization_id}/users/{id}\",\"version\":\"v1\",\"key\":\"0-0-6-5\"},{\"refController\":\"organization-user-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_5\",\"title\":\"/v1/organizations/{organization_id}/users/{id}\",\"version\":\"v1\",\"key\":\"0-0-6-6\"},{\"refController\":\"organization-user-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"disableUserUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/users/{id}/disable\",\"version\":\"v1\",\"key\":\"0-0-6-7\"},{\"refController\":\"organization-user-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"enableUserUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/users/{id}/enable\",\"version\":\"v1\",\"key\":\"0-0-6-8\"},{\"refController\":\"organization-user-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"resetUserPasswordUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/users/{id}/reset\",\"version\":\"v1\",\"key\":\"0-0-6-9\"},{\"refController\":\"organization-user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"unlockUsingGET\",\"title\":\"/v1/organizations/{organization_id}/users/{id}/unlock\",\"version\":\"v1\",\"key\":\"0-0-6-10\"},{\"refController\":\"organization-user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"latestHistoryUsingGET_1\",\"title\":\"/v1/organizations/{organization_id}/users/{user_id}/upload/history\",\"version\":\"v1\",\"key\":\"0-0-6-11\"}],\"title\":\"organization-user-controller\",\"key\":\"0-0-6\"},{\"children\":[{\"refController\":\"project-type-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_8\",\"title\":\"/v1/projects/types\",\"version\":\"v1\",\"key\":\"0-0-7-0\"}],\"title\":\"project-type-controller\",\"key\":\"0-0-7\"},{\"children\":[{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryAllClientsUsingGET\",\"title\":\"/v1/all/clients\",\"version\":\"v1\",\"key\":\"0-0-8-0\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryAllUsersUsingGET\",\"title\":\"/v1/all/users\",\"version\":\"v1\",\"key\":\"0-0-8-1\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"latestHistoryOnOrganizationUsingGET\",\"title\":\"/v1/organizations/{organization_id}/member_role/users/{user_id}/upload/history\",\"version\":\"v1\",\"key\":\"0-0-8-2\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createOrUpdateOnOrganizationLevelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members\",\"version\":\"v1\",\"key\":\"0-0-8-3\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"import2MemberRoleOnOrganizationUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/batch_import\",\"version\":\"v1\",\"key\":\"0-0-8-4\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryClientsByRoleIdOnOrganizationLevelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/clients\",\"version\":\"v1\",\"key\":\"0-0-8-5\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listRolesWithClientCountOnOrganizationLevelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/clients/count\",\"version\":\"v1\",\"key\":\"0-0-8-6\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryClientsWithOrganizationLevelRolesUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/clients/roles\",\"version\":\"v1\",\"key\":\"0-0-8-7\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"deleteOnOrganizationLevelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/delete\",\"version\":\"v1\",\"key\":\"0-0-8-8\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"downloadTemplatesOnOrganizationUsingGET\",\"title\":\"/v1/organizations/{organization_id}/role_members/download_templates\",\"version\":\"v1\",\"key\":\"0-0-8-9\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersByRoleIdOnOrganizationLevelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/users\",\"version\":\"v1\",\"key\":\"0-0-8-10\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listRolesWithUserCountOnOrganizationLevelUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/users/count\",\"version\":\"v1\",\"key\":\"0-0-8-11\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersWithOrganizationLevelRolesUsingPOST\",\"title\":\"/v1/organizations/{organization_id}/role_members/users/roles\",\"version\":\"v1\",\"key\":\"0-0-8-12\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"getUserWithOrgLevelRolesByUserIdUsingGET\",\"title\":\"/v1/organizations/{organization_id}/role_members/users/{user_id}\",\"version\":\"v1\",\"key\":\"0-0-8-13\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"latestHistoryOnProjectUsingGET\",\"title\":\"/v1/projects/{project_id}/member_role/users/{user_id}/upload/history\",\"version\":\"v1\",\"key\":\"0-0-8-14\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createOrUpdateOnProjectLevelUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members\",\"version\":\"v1\",\"key\":\"0-0-8-15\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"import2MemberRoleOnProjectUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/batch_import\",\"version\":\"v1\",\"key\":\"0-0-8-16\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryClientsByRoleIdOnProjectLevelUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/clients\",\"version\":\"v1\",\"key\":\"0-0-8-17\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listRolesWithClientCountOnProjectLevelUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/clients/count\",\"version\":\"v1\",\"key\":\"0-0-8-18\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryClientsWithProjectLevelRolesUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/clients/roles\",\"version\":\"v1\",\"key\":\"0-0-8-19\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"deleteOnProjectLevelUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/delete\",\"version\":\"v1\",\"key\":\"0-0-8-20\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"downloadTemplatesOnProjectUsingGET\",\"title\":\"/v1/projects/{project_id}/role_members/download_templates\",\"version\":\"v1\",\"key\":\"0-0-8-21\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersByRoleIdOnProjectLevelUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/users\",\"version\":\"v1\",\"key\":\"0-0-8-22\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listRolesWithUserCountOnProjectLevelUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/users/count\",\"version\":\"v1\",\"key\":\"0-0-8-23\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersWithProjectLevelRolesUsingPOST\",\"title\":\"/v1/projects/{project_id}/role_members/users/roles\",\"version\":\"v1\",\"key\":\"0-0-8-24\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"getUserWithProjLevelRolesByUserIdUsingGET\",\"title\":\"/v1/projects/{project_id}/role_members/users/{user_id}\",\"version\":\"v1\",\"key\":\"0-0-8-25\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"latestHistoryOnSiteUsingGET\",\"title\":\"/v1/site/member_role/users/{user_id}/upload/history\",\"version\":\"v1\",\"key\":\"0-0-8-26\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createOrUpdateOnSiteLevelUsingPOST\",\"title\":\"/v1/site/role_members\",\"version\":\"v1\",\"key\":\"0-0-8-27\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"import2MemberRoleOnSiteUsingPOST\",\"title\":\"/v1/site/role_members/batch_import\",\"version\":\"v1\",\"key\":\"0-0-8-28\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryClientsByRoleIdOnSiteLevelUsingPOST\",\"title\":\"/v1/site/role_members/clients\",\"version\":\"v1\",\"key\":\"0-0-8-29\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listRolesWithClientCountOnSiteLevelUsingPOST\",\"title\":\"/v1/site/role_members/clients/count\",\"version\":\"v1\",\"key\":\"0-0-8-30\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryClientsWithSiteLevelRolesUsingPOST\",\"title\":\"/v1/site/role_members/clients/roles\",\"version\":\"v1\",\"key\":\"0-0-8-31\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"deleteOnSiteLevelUsingPOST\",\"title\":\"/v1/site/role_members/delete\",\"version\":\"v1\",\"key\":\"0-0-8-32\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"downloadTemplatesOnSiteUsingGET\",\"title\":\"/v1/site/role_members/download_templates\",\"version\":\"v1\",\"key\":\"0-0-8-33\"},{\"refController\":\"role-member-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersOnSiteLevelUsingGET\",\"title\":\"/v1/site/role_members/users\",\"version\":\"v1\",\"key\":\"0-0-8-34\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersByRoleIdOnSiteLevelUsingPOST\",\"title\":\"/v1/site/role_members/users\",\"version\":\"v1\",\"key\":\"0-0-8-35\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listRolesWithUserCountOnSiteLevelUsingPOST\",\"title\":\"/v1/site/role_members/users/count\",\"version\":\"v1\",\"key\":\"0-0-8-36\"},{\"refController\":\"role-member-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersWithSiteLevelRolesUsingPOST\",\"title\":\"/v1/site/role_members/users/roles\",\"version\":\"v1\",\"key\":\"0-0-8-37\"}],\"title\":\"role-member-controller\",\"key\":\"0-0-8\"},{\"children\":[{\"refController\":\"password-policy-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByOrganizationIdUsingGET\",\"title\":\"/v1/organizations/{organization_id}/password_policies\",\"version\":\"v1\",\"key\":\"0-0-9-0\"},{\"refController\":\"password-policy-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPOST_4\",\"title\":\"/v1/organizations/{organization_id}/password_policies/{id}\",\"version\":\"v1\",\"key\":\"0-0-9-1\"}],\"title\":\"password-policy-controller\",\"key\":\"0-0-9\"},{\"children\":[{\"refController\":\"menu-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listAfterTestPermissionUsingGET\",\"title\":\"/v1/menus\",\"version\":\"v1\",\"key\":\"0-0-10-0\"},{\"refController\":\"menu-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_4\",\"title\":\"/v1/menus\",\"version\":\"v1\",\"key\":\"0-0-10-1\"},{\"refController\":\"menu-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST_1\",\"title\":\"/v1/menus/check\",\"version\":\"v1\",\"key\":\"0-0-10-2\"},{\"refController\":\"menu-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listTreeMenusWithPermissionsUsingGET\",\"title\":\"/v1/menus/tree\",\"version\":\"v1\",\"key\":\"0-0-10-3\"},{\"refController\":\"menu-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"saveListTreeUsingPOST\",\"title\":\"/v1/menus/tree\",\"version\":\"v1\",\"key\":\"0-0-10-4\"},{\"refController\":\"menu-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_2\",\"title\":\"/v1/menus/{menu_id}\",\"version\":\"v1\",\"key\":\"0-0-10-5\"},{\"refController\":\"menu-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPOST_3\",\"title\":\"/v1/menus/{menu_id}\",\"version\":\"v1\",\"key\":\"0-0-10-6\"},{\"refController\":\"menu-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteUsingDELETE_5\",\"title\":\"/v1/menus/{menu_id}\",\"version\":\"v1\",\"key\":\"0-0-10-7\"}],\"title\":\"menu-controller\",\"key\":\"0-0-10\"},{\"children\":[{\"refController\":\"dashboard-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_3\",\"title\":\"/v1/dashboards\",\"version\":\"v1\",\"key\":\"0-0-11-0\"},{\"refController\":\"dashboard-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_1\",\"title\":\"/v1/dashboards/{dashboard_id}\",\"version\":\"v1\",\"key\":\"0-0-11-1\"},{\"refController\":\"dashboard-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPOST_1\",\"title\":\"/v1/dashboards/{dashboard_id}\",\"version\":\"v1\",\"key\":\"0-0-11-2\"}],\"title\":\"dashboard-controller\",\"key\":\"0-0-11\"},{\"children\":[{\"refController\":\"system-setting-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"getSettingUsingGET\",\"title\":\"/v1/system/setting\",\"version\":\"v1\",\"key\":\"0-0-12-0\"},{\"refController\":\"system-setting-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"addSettingUsingPOST\",\"title\":\"/v1/system/setting\",\"version\":\"v1\",\"key\":\"0-0-12-1\"},{\"refController\":\"system-setting-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateSettingUsingPUT\",\"title\":\"/v1/system/setting\",\"version\":\"v1\",\"key\":\"0-0-12-2\"},{\"refController\":\"system-setting-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"resetSettingUsingDELETE\",\"title\":\"/v1/system/setting\",\"version\":\"v1\",\"key\":\"0-0-12-3\"},{\"refController\":\"system-setting-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"uploadFaviconUsingPOST\",\"title\":\"/v1/system/setting/upload/favicon\",\"version\":\"v1\",\"key\":\"0-0-12-4\"},{\"refController\":\"system-setting-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"uploadLogoUsingPOST\",\"title\":\"/v1/system/setting/upload/logo\",\"version\":\"v1\",\"key\":\"0-0-12-5\"}],\"title\":\"system-setting-controller\",\"key\":\"0-0-12\"},{\"children\":[{\"refController\":\"eureka-event-endpoint\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_4\",\"title\":\"/v1/eureka/events\",\"version\":\"v1\",\"key\":\"0-0-13-0\"},{\"refController\":\"eureka-event-endpoint\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"retryUsingPOST\",\"title\":\"/v1/eureka/events/retry\",\"version\":\"v1\",\"key\":\"0-0-13-1\"}],\"title\":\"eureka-event-endpoint\",\"key\":\"0-0-13\"},{\"children\":[{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_7\",\"title\":\"/v1/users\",\"version\":\"v1\",\"key\":\"0-0-14-0\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryAdminUsersUsingGET\",\"title\":\"/v1/users/admin\",\"version\":\"v1\",\"key\":\"0-0-14-1\"},{\"refController\":\"user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"addDefaultUsersUsingPOST\",\"title\":\"/v1/users/admin\",\"version\":\"v1\",\"key\":\"0-0-14-2\"},{\"refController\":\"user-controller\",\"method\":\"delete\",\"service\":\"iam-service\",\"operationId\":\"deleteDefaultUserUsingDELETE\",\"title\":\"/v1/users/admin/{id}\",\"version\":\"v1\",\"key\":\"0-0-14-3\"},{\"refController\":\"user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST_6\",\"title\":\"/v1/users/check\",\"version\":\"v1\",\"key\":\"0-0-14-4\"},{\"refController\":\"user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listUsersByEmailsUsingPOST\",\"title\":\"/v1/users/emails\",\"version\":\"v1\",\"key\":\"0-0-14-5\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"getUserIdsUsingGET\",\"title\":\"/v1/users/ids\",\"version\":\"v1\",\"key\":\"0-0-14-6\"},{\"refController\":\"user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUserAndAssignRolesUsingPOST\",\"title\":\"/v1/users/init_role\",\"version\":\"v1\",\"key\":\"0-0-14-7\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByUserEmailUsingGET\",\"title\":\"/v1/users/password_policies\",\"version\":\"v1\",\"key\":\"0-0-14-8\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"querySelfUsingGET\",\"title\":\"/v1/users/self\",\"version\":\"v1\",\"key\":\"0-0-14-9\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryOrganizationsSelfUsingGET\",\"title\":\"/v1/users/self/organizations/paging_query\",\"version\":\"v1\",\"key\":\"0-0-14-10\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryProjectsSelfUsingGET\",\"title\":\"/v1/users/self/projects/paging_query\",\"version\":\"v1\",\"key\":\"0-0-14-11\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryInfoUsingGET\",\"title\":\"/v1/users/{id}/info\",\"version\":\"v1\",\"key\":\"0-0-14-12\"},{\"refController\":\"user-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateInfoUsingPUT\",\"title\":\"/v1/users/{id}/info\",\"version\":\"v1\",\"key\":\"0-0-14-13\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByUserIdOrganizationProjectUsingGET\",\"title\":\"/v1/users/{id}/organization_project\",\"version\":\"v1\",\"key\":\"0-0-14-14\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryOrganizationAndRolesByIdUsingGET\",\"title\":\"/v1/users/{id}/organization_roles\",\"version\":\"v1\",\"key\":\"0-0-14-15\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryOrganizationsUsingGET\",\"title\":\"/v1/users/{id}/organizations\",\"version\":\"v1\",\"key\":\"0-0-14-16\"},{\"refController\":\"user-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"selfUpdatePasswordUsingPUT\",\"title\":\"/v1/users/{id}/password\",\"version\":\"v1\",\"key\":\"0-0-14-17\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryProjectAndRolesByIdUsingGET\",\"title\":\"/v1/users/{id}/project_roles\",\"version\":\"v1\",\"key\":\"0-0-14-18\"},{\"refController\":\"user-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryProjectsUsingGET\",\"title\":\"/v1/users/{id}/projects\",\"version\":\"v1\",\"key\":\"0-0-14-19\"},{\"refController\":\"user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"savePhotoUsingPOST\",\"title\":\"/v1/users/{id}/save_photo\",\"version\":\"v1\",\"key\":\"0-0-14-20\"},{\"refController\":\"user-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"uploadPhotoUsingPOST\",\"title\":\"/v1/users/{id}/upload_photo\",\"version\":\"v1\",\"key\":\"0-0-14-21\"}],\"title\":\"user-controller\",\"key\":\"0-0-14\"},{\"children\":[{\"refController\":\"language-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsingGET\",\"title\":\"/v1/languages\",\"version\":\"v1\",\"key\":\"0-0-15-0\"},{\"refController\":\"language-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByCodeUsingGET\",\"title\":\"/v1/languages/code\",\"version\":\"v1\",\"key\":\"0-0-15-1\"},{\"refController\":\"language-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listAllUsingGET\",\"title\":\"/v1/languages/list\",\"version\":\"v1\",\"key\":\"0-0-15-2\"},{\"refController\":\"language-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_1\",\"title\":\"/v1/languages/{id}\",\"version\":\"v1\",\"key\":\"0-0-15-3\"}],\"title\":\"language-controller\",\"key\":\"0-0-15\"},{\"children\":[{\"refController\":\"organization-project-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_6\",\"title\":\"/v1/organizations/{organization_id}/projects\",\"version\":\"v1\",\"key\":\"0-0-16-0\"},{\"refController\":\"organization-project-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_5\",\"title\":\"/v1/organizations/{organization_id}/projects\",\"version\":\"v1\",\"key\":\"0-0-16-1\"},{\"refController\":\"organization-project-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST_3\",\"title\":\"/v1/organizations/{organization_id}/projects/check\",\"version\":\"v1\",\"key\":\"0-0-16-2\"},{\"refController\":\"organization-project-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_4\",\"title\":\"/v1/organizations/{organization_id}/projects/{project_id}\",\"version\":\"v1\",\"key\":\"0-0-16-3\"},{\"refController\":\"organization-project-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"disableProjectUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/projects/{project_id}/disable\",\"version\":\"v1\",\"key\":\"0-0-16-4\"},{\"refController\":\"organization-project-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"enableProjectUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/projects/{project_id}/enable\",\"version\":\"v1\",\"key\":\"0-0-16-5\"}],\"title\":\"organization-project-controller\",\"key\":\"0-0-16\"},{\"children\":[{\"refController\":\"user-dashboard-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_9\",\"title\":\"/v1/home/dashboard\",\"version\":\"v1\",\"key\":\"0-0-17-0\"},{\"refController\":\"user-dashboard-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPOST_5\",\"title\":\"/v1/home/dashboard\",\"version\":\"v1\",\"key\":\"0-0-17-1\"}],\"title\":\"user-dashboard-controller\",\"key\":\"0-0-17\"},{\"children\":[{\"refController\":\"label-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listByTypeUsingGET\",\"title\":\"/v1/labels\",\"version\":\"v1\",\"key\":\"0-0-18-0\"}],\"title\":\"label-controller\",\"key\":\"0-0-18\"},{\"children\":[{\"refController\":\"organization-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsingGET_1\",\"title\":\"/v1/organizations\",\"version\":\"v1\",\"key\":\"0-0-19-0\"},{\"refController\":\"organization-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST_2\",\"title\":\"/v1/organizations/check\",\"version\":\"v1\",\"key\":\"0-0-19-1\"},{\"refController\":\"organization-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_3\",\"title\":\"/v1/organizations/{organization_id}\",\"version\":\"v1\",\"key\":\"0-0-19-2\"},{\"refController\":\"organization-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_3\",\"title\":\"/v1/organizations/{organization_id}\",\"version\":\"v1\",\"key\":\"0-0-19-3\"},{\"refController\":\"organization-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"disableOrganizationUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/disable\",\"version\":\"v1\",\"key\":\"0-0-19-4\"},{\"refController\":\"organization-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"enableOrganizationUsingPUT\",\"title\":\"/v1/organizations/{organization_id}/enable\",\"version\":\"v1\",\"key\":\"0-0-19-5\"},{\"refController\":\"organization-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryOrgLevelUsingGET\",\"title\":\"/v1/organizations/{organization_id}/org_level\",\"version\":\"v1\",\"key\":\"0-0-19-6\"},{\"refController\":\"organization-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"pagingQueryUsersOnOrganizationUsingGET\",\"title\":\"/v1/organizations/{organization_id}/users\",\"version\":\"v1\",\"key\":\"0-0-19-7\"}],\"title\":\"organization-controller\",\"key\":\"0-0-19\"},{\"children\":[{\"refController\":\"project-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryUsingGET_6\",\"title\":\"/v1/projects/{project_id}\",\"version\":\"v1\",\"key\":\"0-0-20-0\"},{\"refController\":\"project-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_6\",\"title\":\"/v1/projects/{project_id}\",\"version\":\"v1\",\"key\":\"0-0-20-1\"},{\"refController\":\"project-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"disableProjectUsingPUT_1\",\"title\":\"/v1/projects/{project_id}/disable\",\"version\":\"v1\",\"key\":\"0-0-20-2\"},{\"refController\":\"project-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listUsingGET_7\",\"title\":\"/v1/projects/{project_id}/users\",\"version\":\"v1\",\"key\":\"0-0-20-3\"}],\"title\":\"project-controller\",\"key\":\"0-0-20\"},{\"children\":[{\"refController\":\"role-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryByCodeUsingGET_1\",\"title\":\"/v1/roles\",\"version\":\"v1\",\"key\":\"0-0-21-0\"},{\"refController\":\"role-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createUsingPOST_7\",\"title\":\"/v1/roles\",\"version\":\"v1\",\"key\":\"0-0-21-1\"},{\"refController\":\"role-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"createBaseOnRolesUsingPOST\",\"title\":\"/v1/roles/base_on_roles\",\"version\":\"v1\",\"key\":\"0-0-21-2\"},{\"refController\":\"role-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"checkUsingPOST_5\",\"title\":\"/v1/roles/check\",\"version\":\"v1\",\"key\":\"0-0-21-3\"},{\"refController\":\"role-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryIdsByLabelNameAndLabelTypeUsingGET\",\"title\":\"/v1/roles/id\",\"version\":\"v1\",\"key\":\"0-0-21-4\"},{\"refController\":\"role-controller\",\"method\":\"post\",\"service\":\"iam-service\",\"operationId\":\"listUsingPOST_1\",\"title\":\"/v1/roles/search\",\"version\":\"v1\",\"key\":\"0-0-21-5\"},{\"refController\":\"role-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"queryWithPermissionsAndLabelsUsingGET\",\"title\":\"/v1/roles/{id}\",\"version\":\"v1\",\"key\":\"0-0-21-6\"},{\"refController\":\"role-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"updateUsingPUT_7\",\"title\":\"/v1/roles/{id}\",\"version\":\"v1\",\"key\":\"0-0-21-7\"},{\"refController\":\"role-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"disableRoleUsingPUT\",\"title\":\"/v1/roles/{id}/disable\",\"version\":\"v1\",\"key\":\"0-0-21-8\"},{\"refController\":\"role-controller\",\"method\":\"put\",\"service\":\"iam-service\",\"operationId\":\"enableRoleUsingPUT\",\"title\":\"/v1/roles/{id}/enable\",\"version\":\"v1\",\"key\":\"0-0-21-9\"},{\"refController\":\"role-controller\",\"method\":\"get\",\"service\":\"iam-service\",\"operationId\":\"listPermissionByIdUsingGET\",\"title\":\"/v1/roles/{id}/permissions\",\"version\":\"v1\",\"key\":\"0-0-21-10\"}],\"title\":\"role-controller\",\"key\":\"0-0-21\"}]"
    }

}
